package com.lingtianyu.tech.springcloud.grayzone.grey.context;

public class GreyContext {
    private static final ThreadLocal<String> SPRING_CLOUD_ZONE_CONTEXT = new ThreadLocal<>();
    public static void setSpringCloudZone(String zone) {
        SPRING_CLOUD_ZONE_CONTEXT.set(zone);
    }

    public static String getSpringCloudZone() {
        return SPRING_CLOUD_ZONE_CONTEXT.get();
    }

    public static void clear() {
        SPRING_CLOUD_ZONE_CONTEXT.remove();
    }
}
